using System;
using System.Web.UI;
using PHSRAG.Utility;

namespace PHSRAG.Insight21.Humans
{
    /// <summary>
    /// This page redirects to the ViewProtocolPage after
    /// first setting up the incoming cache.
    /// </summary>
    public partial class ViewFullProtocolPage : Page
    {
        /// <summary>
        /// Setups up the outgoing hash and redirects to the ViewProtocolPage.
        /// The only purposes this page serves is to notify the ViewProtocolPage
        /// that a "Full" Protocol should be rendered.  The meaning of "Full"
        /// is protocol process dependent.
        /// </summary>
        /// <param name="sender">sender of the event</param>
        /// <param name="e">arguments of the event</param>
        protected void Page_Load(object sender, EventArgs e)
        {
            if (!IsPostBack)
            {
                Server.Transfer(
                    string.Format("{0}?ViewApplicationType={1}", Settings.GetKeyValue("SubModuleNavigation.Humans.ViewProtocolPageURL", ""), Constants.ViewApplicationType.Full));
            }
        }

        #region Web Form Designer generated code

        /// <summary>
        ///Initilizes the page.
        /// </summary>
        /// <param name="e">arguments of the event</param>
        protected override void OnInit(EventArgs e)
        {
            //
            // CODEGEN: This call is required by the ASP.NET Web Form Designer.
            //
            InitializeComponent();
            base.OnInit(e);
        }

        /// <summary>
        /// Required method for Designer support - do not modify
        /// the contents of this method with the code editor.
        /// </summary>
        private void InitializeComponent()
        {
            this.ID = "ViewProtocolPage";
        }

        #endregion
    }
}